var table;
var element;
var $;
var layer;
layui.use(['table','element','layer'],function(){
    table=layui.table;
    element=layui.element;
    $=layui.jquery;
    layer=layui.layer;


    $("#queId").on("click",function(){
        var Id=$("#ForumMId").val();
        var courseCstatus= $('input[name="courseCstatus"]:checked').val();
        var remarks= $("#textName").val();

        //获取当前登陆人员的信息
        var create=localStorage.getItem("user");
        create=JSON.parse(create);//将获取json字符串转json对象

        $.ajax({
            url:"/courseCheck/updateCourse",
            type:"post",
            dataType:"json",
            data:{"courseCstatus":courseCstatus,"courseId":Id,"createId":create.user_id,"remarks":remarks,"updateId":create.user_id,"courseStatus":2},
            success:function(data){
                if(data.code==0){
                    parent.location.reload();
                }else{
                    layer.msg("审核失败");
                }
            }
        });
        return false;

    });
    $("#quexiaoId").on("click",function(){
        window.parent.location.reload();
    })
});